package com.ljx.common.eneity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * @类名: BaseEntity
 * @描述:
 * @日期: 2020-09-03 15:24
 * @作者: 刘纪譞
 * @版本: 1.0.0
 * <p>
 * since JDK 1.8
 **/

@Data
public class BaseEntity {
    @TableId(value = "id",type= IdType.ASSIGN_ID)
    public Long id;
    @TableField(value = "create_date", fill = FieldFill.INSERT)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    public LocalDateTime createDate;
    @TableField(value = "update_date", fill = FieldFill.UPDATE)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    public LocalDateTime  updateDate;
    public Long operatorId;
}
